﻿using System;
using System.Linq;
using System.Linq.Expressions;

namespace GBlog.Core.Data
{
    public interface IRepository<TEntity> where TEntity : class
    {
        IQueryable<TEntity> GetAll();
        TEntity GetByID(object id);
        void Insert(TEntity entity);
        void Update(TEntity entity);
        void Delete(TEntity entity);
        void Delete(object ID);
        int Count();
        int Count(Expression<Func<TEntity, bool>> Expression);
    }
}